/**
 * 
 */
package com.et114.components.junit;

import org.springframework.test.AbstractTransactionalDataSourceSpringContextTests;

import com.et114.core.common.CONST;

/*
 * @author guanhw
 */
public class BaseSpringTest extends
		AbstractTransactionalDataSourceSpringContextTests {

	
	public BaseSpringTest () {
		super() ;
		try {
			//AllwaysInitServlet.initAppConfig() ;
		}
		catch ( Exception e ) {
			logger.error(  e.getMessage() , e  ) ; 
		}
		
	}
	
	/**
	 * spring 测试引擎调用
	 */
	public final String[] getConfigLocations() {
		if ( getSpringConfigLocations() == null ) {
			return new String[]{ CONST.DEFAULT_SPRING_CONFIG_LOC } ;
		}
		return getSpringConfigLocations() ;
	}
	
	/**
	 * 子类用 指定测试需要加载的spring 的配置文件
	 * @return
	 */
	protected  String[] getSpringConfigLocations () {
		return null;
	}
}
